<!DOCTYPE html>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>Maison des Ligues</title>
        <link rel="stylesheet" href="style/blueberry.css" />
        <link rel="stylesheet" href="style/mainstyle.css" />
        <script src="script/jquery/jquery-1.8.2.min.js"></script>
        <script src="script/blueberry/blueberry.js"></script>
        <script src="script/blueberry/blueberryLaunch.js"></script>
    </head>
    <body>
        <?php
            session_start();
            
            // HEADER
            include_once 'src/website/controller/controller_header.php';

            // FRONT CONTROLLER
            if (isset($_GET['p']))
            {
                $page = $_GET['p'];
                switch ($page)
                {
                    case 'home':
                        require_once 'src/website/controller/controller_home.php';
                        break;
                    case 'league':
                        require_once 'src/website/controller/controller_league.php';
                        break;
                    case 'staff':
                        require_once 'src/website/controller/controller_staff.php';
                        break;
                    case 'log':
                        require_once 'src/website/controller/controller_authentication.php';
                        break;
                    case 'backoffice':
                        require_once 'src/backoffice/controller/controller_main.php';
                        break;
                    default:
                        require_once 'src/website/controller/controller_home.php';
                        break;
                }
            }
            else
            {
                require_once 'src/website/controller/controller_home.php';
            }
        ?>
    </body>
</html>
